import Vue from 'vue'
import VueRouter from 'vue-router'
import HomeView from '../views/HomeView.vue'

Vue.use(VueRouter)

const routes = [
  {
    path: '/',
    name: 'home',
    component: HomeView
  },
  {
    path: '/about',
    name: 'about',
    // route level code-splitting
    // this generates a separate chunk (about.[hash].js) for this route
    // which is lazy-loaded when the route is visited.
    component: () => import(/* webpackChunkName: "about" */ '../views/AboutView.vue')
  },
  {
    path: '/rollover',
    name: 'rollover',
    component: () => import(/* webpackChunkName: "about" */ '../views/RolloverView.vue')
  },
  {
    path: '/icon',
    name: 'icon',
    component: () => import(/* webpackChunkName: "about" */ '../views/function-component/Icon/Icon.vue')
  },
  {
    path: '/button',
    name: 'button',
    component: () => import(/* webpackChunkName: "about" */ '../views/function-component/Button/Button.vue')
  },
  {
    path: '/radio',
    name: 'radio',
    component: () => import(/* webpackChunkName: "about" */ '../views/function-component/Radio/Radio.vue')
  },
  {
    path: '/checkbox',
    name: 'checkbox',
    component: () => import(/* webpackChunkName: "about" */ '../views/function-component/Checkbox/Checkbox.vue')
  },
  {
    path: '/switch',
    name: 'switch',
    component: () => import(/* webpackChunkName: "about" */ '../views/function-component/Switch/Switch.vue')
  },
  {
    path: '/input',
    name: 'input',
    component: () => import(/* webpackChunkName: "about" */ '../views/function-component/Input/Input.vue')
  },
  {
    path: '/textarea',
    name: 'textarea',
    component: () => import(/* webpackChunkName: "about" */ '../views/function-component/Textarea/Textarea.vue')
  },
  {
    path: '/select',
    name: 'select',
    component: () => import(/* webpackChunkName: "about" */ '../views/function-component/Select/Select.vue')
  },
  {
    path: '/pulldown',
    name: 'pulldown',
    component: () => import(/* webpackChunkName: "about" */ '../views/function-component/Pulldown/Pulldown.vue')
  },
  {
    path: '/pager',
    name: 'pager',
    component: () => import(/* webpackChunkName: "about" */ '../views/function-component/Pager/Pager.vue')
  },
  {
    path: '/toolbar',
    name: 'toolbar',
    component: () => import(/* webpackChunkName: "about" */ '../views/function-component/Toolbar/Toolbar.vue')
  },
  {
    path: '/list',
    name: 'list',
    component: () => import(/* webpackChunkName: "about" */ '../views/function-component/List/List.vue')
  },
  {
    path: '/modal',
    name: 'modal',
    component: () => import(/* webpackChunkName: "about" */ '../views/function-component/Modal/Modal.vue')
  },
  {
    path: '/file',
    name: 'file',
    component: () => import(/* webpackChunkName: "about" */ '../views/function-component/File/File.vue')
  },
  {
    path: '/print',
    name: 'print',
    component: () => import(/* webpackChunkName: "about" */ '../views/function-component/Print/Print.vue')
  },
  {
    path: '/form',
    name: 'form',
    component: () => import(/* webpackChunkName: "about" */ '../views/form/BasicForm/BasicForm.vue')
  },
  {
    path: '/custom-layout',
    name: 'custom-layout',
    component: () => import(/* webpackChunkName: "about" */ '../views/form/CustomLayout/CustomLayout.vue')
  },
  {
    path: '/base',
    name: 'base',
    component: () => import(/* webpackChunkName: "about" */ '../views/table/Base.vue')
  },
  {
    path: '/complex',
    name: 'complex',
    component: () => import(/* webpackChunkName: "about" */ '../views/table/Complex.vue')
  },
  {
    path: '/three',
    name: 'three',
    component: () => import(/* webpackChunkName: "about" */ '../views/table/Three.vue')
  },
  {
    path: '/edit',
    name: 'edit',
    component: () => import(/* webpackChunkName: "about" */ '../views/table/Edit.vue')
  },
  {
    path: '/configure',
    name: 'configure',
    component: () => import(/* webpackChunkName: "about" */ '../views/table/Configure.vue')
  },
  {
    path: '/virtual',
    name: 'virtual',
    component: () => import(/* webpackChunkName: "about" */ '../views/virtual/Virtual.vue')
  },
  {
    path: '/format',
    name: 'format',
    component: () => import(/* webpackChunkName: "about" */ '../views/format/Format.vue')
  },
  {
    path: '/instruct',
    name: 'instruct',
    component: () => import(/* webpackChunkName: "about" */ '../views/instruct/Instruct.vue')
  },
  {
    path: '/calibrator',
    name: 'calibrator',
    component: () => import(/* webpackChunkName: "about" */ '../views/calibrator/Calibrator.vue')
  },
  {
    path: '/renderer',
    name: 'renderer',
    component: () => import(/* webpackChunkName: "about" */ '../views/renderer/Renderer.vue')
  },
]

const router = new VueRouter({
  mode: 'history',
  base: process.env.BASE_URL,
  routes
})

export default router
